<%@ page language="java" import="java.util.*,java.net.URLDecoder" pageEncoding="utf-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
String loginName="";
String uid="";
Cookie[] cookArr = request.getCookies();
if(cookArr!=null){
	for(Cookie c:cookArr){
		if(c.getName().equals("LOGINNAME")){
			loginName = URLDecoder.decode(c.getValue(),"UTF-8");
		}
		if(c.getName().equals("UID")){
			uid = c.getValue();
		}
		c.getValue();
	}
}
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<link rel="stylesheet" type="text/css" href="../static/h-ui/css/H-ui.min.css" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/css/H-ui.admin.css" />
<link rel="stylesheet" type="text/css" href="../lib/Hui-iconfont/1.0.8/iconfont.css" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/skin/default/skin.css" id="skin" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/css/style.css" />
<title>修改商品</title>
<link href="lib/webuploader/0.1.5/webuploader.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
		function my(){
			var msg = '${MSG}';
			if(msg!=""){
				alert(msg);
			}
		}
	</script>
</head>
<body onclick="my()">
<div class="page-container">
	<div >修改商品信息:</div>
	<form class="form form-horizontal" id="form-article-add" action="<%=basePath%>shop/updateShop.do" method="post" enctype="multipart/form-data">
		<input type="hidden" name="shop_id" value="${shop.shop_id }">
		<input type="hidden" name="uid" value="${shop.uid }">
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品编号：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="text" class="input-text" value="${shop.shopnumber }"  name="shopnumber">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品名称：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="text" class="input-text" value="${shop.sname }"  name="sname">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品价格：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="text" class="input-text" value="${shop.price }"  name="price">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品类别：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<span class="select-box">
					<c:if test="${shop.product_type =='面膜'}">
						<select name="product_type" class="select">
			   				<option value="面膜" selected="selected">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='护肤套装'}">
						<select name="product_type" class="select">
			   				<option value="护肤套装" selected="selected">护肤套装</option>
			   				<option value="面膜">面膜</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='眼霜'}">
						<select name="product_type" class="select">
			   				<option value="眼霜" selected="selected">眼霜</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='水乳'}">
						<select name="product_type" class="select">
			   				<option value="水乳" selected="selected">水乳</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='口红'}">
						<select name="product_type" class="select">
			   				<option value="口红" selected="selected">口红</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='精华'}">
						<select name="product_type" class="select">
			   				<option value="精华" selected="selected">精华</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='洁面'}">
						<select name="product_type" class="select">
			   				<option value="洁面" selected="selected">洁面</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='粉底'}">
						<select name="product_type" class="select">
			   				<option value="粉底" selected="selected">粉底</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="美妆工具">美妆工具</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='香水'}">
						<select name="product_type" class="select">
			   				<option value="香水" selected="selected">香水</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type =='眼影眼线'}">
						<select name="product_type" class="select">
			   				<option value="眼影眼线" selected="selected">眼影眼线</option>
			   				<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="美妆工具">美妆工具</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type ==null}">
						<select name="product_type" class="select">
							<option value="0" selected="selected">全部分类</option>
							<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="香水">香水</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
					<c:if test="${shop.product_type=='0'}">
						<select name="product_type" class="select">
							<option value="0" selected="selected">全部分类</option>
							<option value="面膜">面膜</option>
							<option value="护肤套装">护肤套装</option>
							<option value="眼霜">眼霜</option>
							<option value="水乳">水乳</option>
							<option value="口红">口红</option>
							<option value="精华">精华</option>
							<option value="洁面">洁面</option>
							<option value="粉底">粉底</option>
							<option value="香水">香水</option>
							<option value="眼影眼线">眼影眼线</option>
						</select>
					</c:if>
				</span>
			</div>
		</div>
		
		<c:if test="${shop.sstatic ==0}">
			<input type="hidden" class="input-text" value="0" name="sstatic" >
		</c:if>
		<c:if test="${shop.sstatic ==1 }">
			<input type="hidden" class="input-text" value="1" name="sstatic" >
		</c:if>
			
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品库存：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="text" class="input-text" value="${shop.stock }" name="stock">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2">上架日期：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="date" id="datemin" class="input-text Wdate" name="time" value="${shop.time}">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品描述：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="text"  id="datemax" class="input-text Wdate" name="sdescribe" style="width:1095px;height:150px" value="${shop.sdescribe }">
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-2"><span style="color: red;">*</span>商品图片：</label>
			<div class="formControls col-xs-8 col-sm-9">
				<input type="file" name="myPic" /><br>
				<c:if test="${shop.picture!=null }">
					<img src="${shop.picture }" width="100px" height="100px"/>
				</c:if>
				<input type="hidden" name="picture" value="${shop.picture }">
			</div>
		</div>
		<div class="row cl">
			<div class="formControls col-xs-8 col-sm-9">
				<input type="file" name="mylongPic" /><br>
				<c:if test="${shop.images!=null }">
					<img src="${shop.images }" width="100px" height="100px"/>
				</c:if>
				<input type="hidden" name="images" value="${shop.images }">
			</div>
		</div>
		<div class="row cl">
			<div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-2">
				<input type="submit" class="btn btn-primary radius" type="button" value="修改并提交审核">
			</div>
		</div>
	</form>
</div>


<!--_footer 作为公共模版分离出去-->
<script type="text/javascript" src="../lib/jquery/1.9.1/jquery.min.js"></script> 
<script type="text/javascript" src="../lib/layer/2.4/layer.js"></script>
<script type="text/javascript" src="../static/h-ui/js/H-ui.min.js"></script> 
<script type="text/javascript" src="../static/h-ui.admin/js/H-ui.admin.js"></script> <!--/_footer /作为公共模版分离出去-->

<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="../lib/jquery.validation/1.14.0/jquery.validate.js"></script> 
<script type="text/javascript" src="../lib/jquery.validation/1.14.0/validate-methods.js"></script> 
<script type="text/javascript" src="../lib/jquery.validation/1.14.0/messages_zh.js"></script> 
<script type="text/javascript" src="../lib/webuploader/0.1.5/webuploader.min.js"></script> 
>
</body>
</html>
